package dp.gr03.payroll.classificationTransaction;

import dp.gr03.payroll.classifications.CommissionedClassification;
import dp.gr03.payroll.payrollDomain.PaymentClassification;
import dp.gr03.payroll.payrollDomain.PaymentSchedule;
import dp.gr03.payroll.schedules.BiweeklySchedule;

public class ChangeCommissionTransaction extends ChangeClassificationTransaction
{

    private double commissionRate;
    private double salary;

    public ChangeCommissionTransaction(int empId, double commissionRate, double salary)
    {
        super(empId);
        this.commissionRate = commissionRate;
        this.salary = salary;
    }

    @Override
    public PaymentClassification getPaymentClassification()
    {
        return new CommissionedClassification(salary, commissionRate);
    }

    @Override
    public PaymentSchedule getPaymentSchedule()
    {
        return new BiweeklySchedule();
    }

}
